CC = @gcc

# options: -DDEBUG for debugging purposes; -DNOCAMERA for creating "local" images (minimum inter arrival time); -DPERFORMANCE for measuring the completion time
CFLAGS = -Wall -pedantic -DNOCAMERA -DPERFORMANCE

GSL_LIB = -lgsl -lgslcblas
LIB = $(GSL_LIB) -lm -ltiff

objects = connect.o image.o interpolator.o

.PHONY: clean

# compilation options and dependencies

interpolator: $(objects)
	$(CC) $(CFLAGS) $(LIB) $(objects) -o interpolator

interpolator.o: interpolator.c image.h connect.h

connect.o: connect.c connect.h

image.o: image.c image.h gaussian.h

# other targets

clean:
	@echo "\nDeleting old files"
	@-rm -f ./interpolator $(objects) *~ ./Debug/*.tiff

